From 0c329a57d5d2edf2829b7aeb161f3d5217affc4d Mon Sep 17 00:00:00 2001 From: robertl Date: Fri, 16 Jan 2004 16:34:52 +0000 Subject: [PATCH] Make format strings consistent for -vs output. --- gpsbabel/garmin.c | 4 +++- gpsbabel/magproto.c | 1 - gpsbabel/waypt.c | 3 ++- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/gpsbabel/garmin.c b/gpsbabel/garmin.c index f1f4bf690..d36650d91 100644 --- a/gpsbabel/garmin.c +++ b/gpsbabel/garmin.c @@ -308,9 +308,11 @@ static int waypt_write_cb(GPS_PWay *way) { static int i; + int n = waypt_count(); if (global_opts.verbose_status) { - fprintf(stdout, "%d\r", ++i*100/waypt_count()); + i++; + fprintf(stdout, "%d/%d/%d\r", i*100/n, i, n); fflush(stdout); } return 0; diff --git a/gpsbabel/magproto.c b/gpsbabel/magproto.c index 56c65d167..5ec4fdb80 100644 --- a/gpsbabel/magproto.c +++ b/gpsbabel/magproto.c @@ -389,7 +389,6 @@ retry: * we'll be fairly persistent in retrying. */ if (retrycnt--) { - warning( "%d\n", retrycnt); goto retry; } else { fatal(MYNAME ": No data received from GPS.\n"); diff --git a/gpsbabel/waypt.c b/gpsbabel/waypt.c index 8e082d6a1..51c7f0f90 100644 --- a/gpsbabel/waypt.c +++ b/gpsbabel/waypt.c @@ -142,7 +142,8 @@ waypt_disp_all(waypt_cb cb) QUEUE_FOR_EACH(&waypt_head, elem, tmp) { waypointp = (waypoint *) elem; if (global_opts.verbose_status) { - fprintf(stdout, "%d\r", ++i*100/waypt_ct); + i++; + fprintf(stdout, "%d/%d/%d\r", i*100/waypt_ct, i, waypt_ct); fflush(stdout); } (*cb) (waypointp); -- 2.30.2